<% provide(:title, @user.name) %>
<div id="main-wrap">
  <div class="user-page">
    <div class="row">
      <aside class="col-md-4">
        <section>
          <h1>
            <%= gravatar_for @user %>
            <%= @user.name %>
          </h1>
        </section>
        <section class="stats">
          <%= render 'shared/stats' %>
        </section>
        <section class="micropost_form">
          <%= render 'shared/micropost_form' %>
        </section>
      </aside>
      <div class="col-md-8">
        <%= render 'follow_form' if logged_in? %>
        <% if @user.microposts.any? %>
            <h2 class="center">微博广场(<%= Micropost.count %>)</h2>
            <ol class="microposts">
              <%= render @microposts %>
            </ol>
            <%= will_paginate @microposts %>
        <% end %>
      </div>
    </div>
  </div>
</div>